package com.example.weli.ble2test;

import android.graphics.drawable.Drawable;

public class Utilities {
    static void centerAround(int x, int y, Drawable d) {
        int w = d.getIntrinsicWidth();
        int h = d.getIntrinsicHeight();
        int left = x - (w / 2);
        int top = y - (h / 2);
        d.setBounds(left, top, left + w, top + h);
    }
}
